﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

[DataContract]

public class CinemaRoom
{
    /// <summary>
   /// Constructs a CinemaRoom object with an id, screen, maximum seats 
   /// and maximum length of seats
   /// </summary>
   /// <param name="id"></param>
   /// <param name="screen"></param>
   /// <param name="maxSeats"></param>
   /// <param name="maxLengthSeats"></param>
    public CinemaRoom(int id, string screen, int maxSeats, int maxLengthSeats)
    {
        Id = id;
        Screen = screen;
        MaxSeats = maxSeats;
        MaxLengthSeats = maxLengthSeats;

    }
    /// <summary>
    /// Get and Set Cinema Room ID number
    /// </summary>
    [DataMember]
	public int Id
	{
		get;
		set;
	}
    /// <summary>
    /// Get and Set Screen
    /// </summary>
    [DataMember]
	public string Screen
	{
		get;
		set;
	}
    /// <summary>
    /// Get and Set Amount of bookings in each Cinema Room
    /// </summary>
    [DataMember]
	public int AmountOfBookings
	{
		get;
		set;
	}
    /// <summary>
    /// Get and Set Max Seats
    /// </summary>
    [DataMember]
	public int MaxSeats
	{
		get;
		set;
	}
    /// <summary>
    /// Get and Set Max length of Seats
    /// </summary>
    [DataMember]
    public int MaxLengthSeats 
    { 
        get; 
        set; 
    }
    /// <summary>
    /// Get and Set Seat list
    /// </summary>
    [DataMember]
	public List<Seat> Seats
	{
		get;
		set;
	}
    /// <summary>
    /// Get and Set Show time list
    /// </summary>
    [DataMember]
	public List<ShowTime> Shows
	{
		get;
		set;
	}
    /// <summary>
    /// Add Seat  object to Seat list
    /// </summary>
    /// <param name="seat"></param>
   
	public void AddSeat(Seat seat)
	{
        Seats.Add(seat);
	}
    /// <summary>
    /// Delete Seat object from Seat list
    /// </summary>
    /// <param name="seat"></param>
	public void DeleteSeat(Seat seat)
	{
        Seats.Remove(seat);
	}
    /// <summary>
    /// Add ShowTime to Show List
    /// </summary>
    /// <param name="shTime"></param>
	public void AddShowTime(ShowTime shTime)
	{
        Shows.Add(shTime);
	}
    /// <summary>
    /// Delete ShowTime from Show list
    /// </summary>
    /// <param name="shTime"></param>
	public void DeleteShowTime(ShowTime shTime)
	{
        Shows.Remove(shTime);
	}

}

